#include "SceneModule.h"


SceneModule::SceneModule(void)
	:_sceneLayer(nullptr)
{

}


SceneModule::~SceneModule(void)
{

}

bool SceneModule::init()
{
	_sceneLayer = SceneView::create();

	_sceneLayer->initMap(1001);

	EventMgr::inst()->addEventListener("add_object_in_scene", this, &SceneModule::onAddObjectToScene);

	return true;
}

void SceneModule::destroy()
{
	DELETE_POINTER(_sceneLayer);

	EventMgr::inst()->removeEventListener("add_object_in_scene", this, &SceneModule::onAddObjectToScene);
}

void SceneModule::show( void* data )
{

}

void SceneModule::close()
{

}

void SceneModule::onAddObjectToScene( TagEvent* event )
{

}


void SceneModule::addObjectToScene( unsigned long id, Node* obj )
{

}

Node* SceneModule::findObject()
{
	return nullptr;
}

void SceneModule::resetMap()
{
	_sceneLayer->removeAllObject();
}
